<template>
    <div>
        <el-form ref="form" :model="form" label-width="80px">
            <el-form-item label="所属栏目">
                <el-input v-model="form.character"></el-input>
            </el-form-item>
            <el-form-item label="文章标题">
                <el-input v-model="form.title"></el-input>
            </el-form-item>
            <el-form-item label="文章摘要">
                <el-input type="textarea" v-model="form.description"></el-input>
            </el-form-item>
            <el-form-item label="封面图片">
                <el-input v-model="form.logo"></el-input>
            </el-form-item>
            <!-- 富文本编辑器 -->
            <el-form-item label="文章内容">
                <tinymce :height="300" v-model="form.detail"></tinymce>
            </el-form-item>
            <el-form-item label="状态">
                <el-select v-model="form.select" placeholder="请选择">
                    <el-option
                      v-for="item in form.select"
                      :key="item.id"
                      :label="item.label"
                      :value="item.id">
                    </el-option>
                </el-select>
            </el-form-item>
        </el-form>
    </div>
</template>
<script>
import Tinymce from '@/components/Tinymce'

export default {
  components: {
    Tinymce
  },
  data() {
    return {
      form: {
        select: [{
          id: 0,
          label: '发布'
        }, {
          id: 1,
          label: '隐藏'
        }, {
          id: 2,
          label: '草稿'
        }],
        character: '',
        title: '',
        description: '',
        logo: '',
        screenshot: '',
        detail: ''
      }
    }
  }
}
</script>
